home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Amiga Tools 2
/
Amiga Tools 2.iso
/
tex
/
macros
/
source
/
packages
/
epic
/
picman.tex
/
node12_mn.html
< prev
next >
Wrap
Text File
|
1995-03-15
|
3KB
|
59 lines
<H2><A ID="SECTION00039000000000000000">
<TT>\</TT>putfile</A>
</H2>
<P>
<#482#><TT>\putfile{<#193#><I>filename</I><#193#>}{<#194#><I>object</I><#194#>}</TT><#482#>
<P>
The command <tex2html_verb_mark>90<tex2html_verb_mark> is similar to the <tex2html_verb_mark>91<tex2html_verb_mark> command except that
the <I>x</I> and <I>y</I> coordinates required by the <tex2html_verb_mark>92<tex2html_verb_mark> command are read from
an external file and the same <#195#><I>object</I><#195#> is plotted at each of those
coordinates.
<P>
The motivation behind this command is that T<SMALL>E</SMALL>X does not have the capability
to do floating point calculations which would be required if one wished
to plot any parametric curve other than straight lines. Coordinates for such
curves can be easily generated by programs in other languages and
subsequently a ``dotted'' curve can be plotted via T<SMALL>E</SMALL>X or L<SUP><SMALL>A</SMALL></SUP>T<SMALL>E</SMALL>X. Even if
coordinates for certain curves could be generated from within T<SMALL>E</SMALL>X, it is
much more efficient to use other languages --- eventually only the
coordinates of the points are required.
For instance, one can use the Unix<A NAME="tex2html2" HREF="footnode_mn.html#foot483" TARGET="footer"><SUP>4</SUP></A> facility
<#197#><I>spline</I><#197#> to generate smooth curves with equidistant ``dots''.
<P>
<#198#><B>Format of the External File:</B><#198#> The external file of coordinates must have
``<I>x</I> <I>y</I> '' pairs, one pair on each line, with a space between them. Also, it
is suggested that some extension such as ``<#199#><TT>.put</TT><#199#>'' be used for such
data files to distinguish them from regular text files in which case it must
be explicitly specified in the first argument so that T<SMALL>E</SMALL>X doesn't look for
a ``<#200#><TT>.tex</TT><#200#>'' extension.
<P>
The ``<#201#><TT><tex2html_percent_mark></TT><#201#>'' character remains valid as a comment character and such lines
are ignored. However, there should be at least one space after the second
entry if a comment is on the same line as data since <#202#><TT><tex2html_percent_mark></TT><#202#> eats up the
newline.
<P>
For example, to plot a smooth curve along a set of coordinates, one may
undertake the following steps:
<OL>
<LI>have a file of ``<I>x</I> <I>y</I>'' coordinates for original data points, say,
<#204#><TT>datafile</TT><#204#>.
</LI>
<LI>run the command (for Unix systems): <#205#><TT>spline -200 datafile ;SPMgt;
data.put</TT><#205#>
</LI>
<LI>in a picture environment in a L<SUP><SMALL>A</SMALL></SUP>T<SMALL>E</SMALL>X file, put the command:
<BR> <tex2html_verb_mark>93<tex2html_verb_mark>
<BR>(see previous section for explanation of <tex2html_verb_mark>94<tex2html_verb_mark>).
</LI>
</OL>
<P>